from dataaccess import SongData
from common import utility

class SongBiz(object):
    def __init__(self):
        pass

    def __ValidateInsert(self, song):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def __ValidateUpdate(self, song):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def __ValidateDelete(self, songID):
        valid = True
        if not valid:
            raise utility.BusinessException(message="",fieldName = "")
        
    def InsertSong(self, song):
        self.__ValidateInsert(song)
        songData = SongData.SongData()
        return songData.InsertSong(song)

    def UpdateSong(self, song):
        self.__ValidateUpdate(song)
        songData = SongData.SongData()
        songData.UpdateSong(song)

    def DeleteSong(self, songID):
        self.__ValidateDelete(songID)
        songData = SongData.SongData()
        songData.DeleteSong(songID)
